<?php $__env->startSection('extra_css'); ?>
    <?php if($settings_general->site_post_as_titles == 1): ?>
        <title><?php echo e($page->title); ?></title>
    <?php else: ?>
        <title><?php echo e($settings_general->site_title); ?></title>
    <?php endif; ?>

    <meta name="keywords" content="<?php echo e($page->seo_keywords); ?>">

    <meta name="description" content="<?php echo e(\Illuminate\Support\Str::limit(trim(strip_tags($page->description)),300)); ?>">

    <!--Twitter Card-->
    <meta property="twitter:card" content="summary"/>
    <meta property="twitter:site" content="<?php echo e($settings_social->twitter_handle); ?>"/>
    <meta property="twitter:title" content="<?php echo e($page->title); ?>"/>
    <meta property="twitter:description"
          content="<?php echo e(\Illuminate\Support\Str::limit(trim(strip_tags($page->description)),300)); ?>"/>
    <meta name="twitter:creator" content="<?php echo e($settings_social->twitter_handle); ?>">
    <meta property="twitter:url" content="<?php echo e(URL::to('/page/'.$page->slug)); ?>"/>

    <!--Og tags-->
    <meta property="og:site_name" content="<?php echo e($settings_general->site_title); ?>"/>
    <meta property="og:title" content="<?php echo e($page->title); ?>"/>
    <meta property="og:description"
          content="<?php echo e(\Illuminate\Support\Str::limit(trim(strip_tags($page->description)),300)); ?>"/>
    <meta property="og:type" content="article"/>
    <meta property="og:url" content="<?php echo e(URL::to($page->slug)); ?>"/>

    <meta property="article:published_time" content="<?php echo e($page->created_at); ?>"/>
    <meta property="article:modified_time" content="<?php echo e($page->updated_at); ?>"/>

<?php $__env->stopSection(); ?>

<?php $__env->startSection('extra_js'); ?>
    <?php if(strlen($settings_social->addthis_js) > 0 && $settings_social->show_sharing == 1): ?>
        <?php echo $settings_social->addthis_js; ?>

    <?php endif; ?>

    <?php if(strlen($settings_social->sharethis_js) > 0 && $settings_social->show_sharing == 1): ?>
        <?php echo $settings_social->sharethis_js; ?>

    <?php endif; ?>

    <?php if($settings_comments->comment_system == \App\Posts::COMMENT_FACEBOOK): ?>
        <?php echo $settings_comments->fb_js; ?>

    <?php endif; ?>
<?php $__env->stopSection(); ?>

<?php $__env->startSection('content'); ?>

    <div class="container main-wrapper">

        <?php if(!empty($ads[\App\Ads::TYPE_ABOVE_PAGE])): ?>
            <div class="mag-content clearfix">
                <div class="row">
                    <div class="col-md-12">
                        <div class="ad728-wrapper">

                            <?php echo $ads[\App\Ads::TYPE_ABOVE_PAGE]->code; ?>


                        </div>
                    </div>
                </div>
            </div>
        <?php endif; ?>


        <div class="main-content mag-content clearfix">

            <div class="row blog-content">

                <div class="col-md-8">

                    <?php echo $__env->make('admin.layouts.notify', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>

                    <article class="post-wrapper clearfix">

                        <header class="post-header">
                            <h1 class="post-title">
                                <?php echo e($page->title); ?>

                            </h1><!-- .post-title -->

                            <p class="simple-share">
                                <span>by <a href="/author/<?php echo e($page->author->slug); ?>"><b><?php echo e($page->author->name); ?></b></a></span>
                            <span><span class="article-date"><i
                                            class="fa fa-clock-o"></i> <?php echo e($page->created_at->diffForHumans()); ?></span></span>
                                <span><i class="fa fa-eye"></i> <?php echo e($page->views); ?> views</span>

                                <?php if($settings_comments->fb_comment_count == 1): ?>
                                    <?php if($settings_comments->comment_system == \App\Posts::COMMENT_FACEBOOK): ?>
                                        <span class="comments-count">
                                        <i class="fb-comments-count" data-href="<?php echo e(URL::full()); ?>"></i>comments
                                        </span>
                                    <?php endif; ?>
                                <?php endif; ?>

                                <?php if($settings_comments->disqus_comment_count == 1): ?>
                                    <?php if($settings_comments->comment_system == \App\Posts::COMMENT_DISQUS): ?>
                                        <a class="comments-count" href="<?php echo e(URL::full()); ?>#disqus_thread">0</a>
                                    <?php endif; ?>
                                <?php endif; ?>

                            </p>

                        </header>

                        <div class="post-content clearfix"><?php echo $page->description; ?></div>

                        <footer class="post-meta">

                            <div class="share-wrapper clearfix">
                                <?php if(strlen($settings_social->addthis_js) > 0 && $settings_social->show_sharing == 1): ?>
                                    <div class="addthis_sharing_toolbox"></div>
                                <?php endif; ?>

                                <?php if(strlen($settings_social->sharethis_span_tags) > 0 && strlen($settings_social->sharethis_js) > 0 && $settings_social->show_sharing == 1): ?>
                                    <?php echo $settings_social->sharethis_span_tags; ?>

                                <?php endif; ?>
                            </div>

                            <div class="author-box clearfix">
                                <div class="author-avatar">
                                    <a href="/author/<?php echo e($page->author->slug); ?>">
                                        <img alt="" src="<?php echo e(URL::to($page->author->avatar)); ?>" class="avatar"
                                             height="110"
                                             width="110">
                                    </a>
                                </div>
                                <div class="author-info">
                                    <h3><a href="/author/<?php echo e($page->author->slug); ?>"><?php echo e($page->author->name); ?></a></h3>

                                    <p class="author-bio">
                                        <?php echo e($page->author->bio); ?>

                                    </p>

                                    <div class="author-contact">
                                        <?php if(strlen($page->author->email)>0): ?>
                                            <a href="mailto:<?php echo e($page->author->email); ?>"><i
                                                        class="fa fa-envelope fa-lg"
                                                        title="Email"></i></a>
                                        <?php endif; ?>
                                        <?php if(strlen($page->author->website_url)>0): ?>
                                            <a href="<?php echo e($page->author->website_url); ?>" target="_blank"><i
                                                        class="fa fa-globe fa-lg"
                                                        title="Website"></i></a>
                                        <?php endif; ?>

                                        <?php if(strlen($page->author->fb_url)>0): ?>
                                            <a href="<?php echo e($page->author->fb_url); ?>" target="_blank"><i
                                                        class="fa fa-facebook fa-lg"
                                                        title="Facebook"></i></a>
                                        <?php endif; ?>

                                        <?php if(strlen($page->author->twitter_url)>0): ?>
                                            <a href="<?php echo e($page->author->twitter_url); ?>" target="_blank"><i
                                                        class="fa fa-twitter fa-lg"
                                                        title="Twitter"></i></a>
                                        <?php endif; ?>

                                        <?php if(strlen($page->author->google_plus_url)>0): ?>
                                            <a href="<?php echo e($page->author->google_plus_url); ?>" rel="publisher"
                                               target="_blank"><i title="Google+"
                                                                  class="fa fa-google-plus fa-lg"></i></a>
                                        <?php endif; ?>

                                    </div>
                                </div>
                            </div>

                        </footer>

                    </article>

                    <?php if(!empty($ads[\App\Ads::TYPE_BELOW_PAGE])): ?>
                        <div class="row">
                            <div class="col-md-12">
                                <?php echo $ads[\App\Ads::TYPE_BELOW_PAGE]->code; ?>

                            </div>
                        </div>
                    <?php endif; ?>

                    <?php if($settings_comments->comment_system == \App\Posts::COMMENT_DISQUS): ?>
                        <div id="comments" class="comments-wrapper clearfix">
                            <h3 class="block-title"><span>Comments</span></h3>

                            <?php echo $settings_comments->disqus_js; ?>


                        </div>
                    <?php endif; ?>

                    <?php if($settings_comments->comment_system == \App\Posts::COMMENT_FACEBOOK): ?>
                        <div id="comments" class="comments-wrapper clearfix">
                            <h3 class="block-title"><span>Comments</span></h3>

                            <div class="fb-comments" data-href="<?php echo e(URL::full()); ?>"
                                 data-numposts="<?php echo e(empty($settings_comments->fb_num_posts)?5:$settings_comments->fb_num_posts); ?>"></div>

                        </div>
                    <?php endif; ?>


                </div>

                <div class="col-md-4">
                    <?php echo $__env->make('layouts.sidebar', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
                </div>
            </div>

        </div>
    </div>
<?php $__env->stopSection(); ?>


<?php echo $__env->make('layouts.master', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>